home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 2006 July & August
/
PCWorld_2006-07-08_cd.bin
/
v cisle
/
acehtml
/
acehtmlfreeware.exe
/
scriptdef
/
One-Letter Scroller.sd
< prev
next >
Wrap
INI File
|
2004-06-28
|
2KB
|
71 lines
[SUBJECT]
Description=Scroll one letter at a time of your message until the entire message has been displayed
ImageIndex=-1
Folder=Text Effects
[HEAD_TEXT]
;
;<!-- Original: Pun Man Kit <mkpunnl@netvigator.com> -->
;
;<!-- This script and many more are available free online at -->
;<!-- The JavaScript Source!! http://javascript.internet.com -->
;
;<script language="JavaScript">
;<!-- Begin
;function scroll(jumpSpaces,position) {
;var msg = "`message`";
;var out = "";
;if (killScroll) {return false;}
;for (var i=0; i<position; i++){
;out += msg.charAt(i);}
;for (i=1;i<jumpSpaces;i++) {
;out += " ";}
;out += msg.charAt(position);
;window.status = out;
;if (jumpSpaces <= 1) {
;position++;
;if (msg.charAt(position) == ' ') {
;position++;}
;jumpSpaces = 100-position;
;}
;else if (jumpSpaces > 3) {
;jumpSpaces = jumpSpaces * .75;}
;else {
;jumpSpaces--;}
;if (position != msg.length) {
;var cmd = "scroll(" + jumpSpaces + "," + position + ")";
;scrollID = window.setTimeout(cmd,5);
;}
;else {
;scrolling = false;
;return false;}
;return true;
;}
;function startScroller() {
;if (scrolling)
;if (!confirm('Re-initialize snapIn?'))
;return false;
;killScroll = true;
;scrolling = true;
;var killID = window.setTimeout('killScroll=false',6);
;scrollID = window.setTimeout('scroll(100,0)',10);
;return true;
;}
;var scrollID = Object;
;var scrolling = false;
;var killScroll = false;
;// End -->
;</script>
[BODY_TAG]
;onLoad="startScroller()"
[`message`]
Kind=S
Value=Another JavaScript Example! Do you like it?